<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div id="char1" style="background-color: pink;height: 500px;width: 600px;"></div>
    <script src="../js/eharts.min.4.7.0.js"></script>
    <script>
        var c1 = echarts.init(char1);
        // c1.setOption({
        //     // xAxis: {
        //     //     name:"衣服销量",
        //     //     data: ["衬衫", "羊毛衫", "雪纺衫"]
        //     // },
        //     // yAxis: {}, 
        //     series: [{
        //         name: '销量',
        //         radius: '35%',
        //         // type: 'line',
        //         type: 'pie',
        //         data: [5, 70, 36]
        //     }]
        // });
        c1.setOption({
  title: {
    text: '引用网站上的数据',
    subtext: 'Fake Data',
    left: 'center'
  },
  tooltip: {
    trigger: 'item'
  },
  legend: {
    orient: 'vertical',
    left: 'left'
  },
  series: [
    {
      name: 'Access From',
      type: 'pie',
      radius: '50%',
      data: [
        { value: 1048, name: 'Search Engine' },
        { value: 735, name: 'Direct' },
        { value: 580, name: 'Email' },
        { value: 484, name: 'Union Ads' },
        { value: 300, name: 'Video Ads' }
      ],
      emphasis: {
        itemStyle: {
          shadowBlur: 10,
          shadowOffsetX: 0,
          shadowColor: 'rgba(0, 0, 0, 0.5)'
        }
      }
    }
  ]
});

    </script>
</body>
</html>